<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('新增消息列')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-message-add">
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">标题：</label>
                <div class="col-sm-8">
                    <input name="title" class="form-control" type="text" required>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label is-required">消息类型：</label>
                <div class="col-sm-8">
                    <select name="type" class="form-control m-b">
                        <option value="1" name="type">服务商消息</option>
                        <option value="2" name="type">商户消息</option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">类型：</label>
                <div class="col-sm-8">
                    <select name="status" class="form-control m-b">
                        <option value="1" name="status">系统消息</option>
                        <option value="2" name="status">小喇叭消息</option>
                        <option value="3" name="status">常见问题</option>
                        <option value="4" name="status">活动消息</option>
                        <option value="5" name="status">奖励消息</option>
                        <option value="6" name="status">公告消息</option>
                        <option value="7" name="status">订单消息</option>
                        <option value="8" name="status">机具消息</option>
                        <option value="9" name="status">雏鹰入口</option>
                        <option value="10" name="status">雏鹰详情</option>
                    </select>
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label is-required">极光推送消息状态：</label>
                <div class="col-sm-8">
                    <select name="jgStatus" class="form-control m-b">
                        <option value="0" name="jgStatus">未推送</option>
                        <option value="1" name="jgStatus">已推送</option>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">限制档位：</label>
                <div class="col-sm-8">
                    <select name="grade" class="form-control m-b">
                        <option value="" >请选择</option>
                        <option value="V1" >V1</option>
                        <option value="V2" >V2</option>
                        <option value="V3" >V3</option>
                        <option value="V4" >V4</option>
                        <option value="V5" >V5</option>
                        <option value="V6" >V6</option>
                        <option value="V7" >V7</option>
                        <option value="V8" >V8</option>
                        <option value="V9" >V9</option>
                        <option value="V10" >V10</option>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label is-required">消息内容：</label>
                <div class="col-sm-8">
                    <textarea cols="10" rows="10" name="content" class="form-control" required></textarea>
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "message/message"
        $("#form-message-add").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/add", $('#form-message-add').serialize());
            }
        }
    </script>
</body>
</html>